package com.luhuiguo.gwt.mvp.dispatcher.server;

import com.luhuiguo.gwt.mvp.dispatcher.shared.rpc.Action;
import com.luhuiguo.gwt.mvp.dispatcher.shared.rpc.Result;


/**
 * This contains both the original {@link Action} and the {@link Result} of that
 * action.
 * 
 * @author LuHuiguo
 * @version $Id: ActionResult.java 11 2009-12-26 13:39:17Z luhuiguo $
 * 
 * @param <A>
 *            The action type.
 * @param <R>
 *            The result type.
 */
public class ActionResult<A extends Action<R>, R extends Result> {
    
    private final A action;

    private final R result;

    public ActionResult( A action, R result ) {
        this.action = action;
        this.result = result;
    }

    public A getAction() {
        return action;
    }

    public R getResult() {
        return result;
    }
}
